// API配置文件
const API_CONFIG = {
  // 基础URL
  BASE_URL: 'http://localhost:5252/api',

  // 认证相关API
  AUTH: {
    LOGIN: '/auth/login',
    REGISTER: '/auth/register',
    LOGOUT: '/auth/logout',
    VALIDATE: '/auth/validate',
    SEND_VERIFICATION_CODE: '/auth/send-verification-code',
    RESET_PASSWORD: '/auth/reset-password'
  },

  // 用户管理API
  USER: {
    LIST: '/user/list',
    TREE: '/user/tree',
    CREATE: '/user/create',
    UPDATE: '/user/update',
    DELETE: '/user/delete'
  },

  // 角色管理API
  ROLE: {
    LIST: '/role/list',
    CREATE: '/role/create',
    UPDATE: '/role/update',
    DELETE: '/role/delete'
  },

  // 权限管理API
  PERMISSION: {
    LIST: '/permission/list',
    CREATE: '/permission/create',
    UPDATE: '/permission/update',
    DELETE: '/permission/delete'
  },

  // 日志管理API
  LOG: {
    LIST: '/log/list',
    STATISTICS: '/log/statistics',
    EXPORT: '/log/export',
    CLEAN: '/log/clean'
  },

  // 文件管理API
  FILE: {
    LIST: '/file/list',
    SEARCH: '/file/search',
    UPLOAD: '/file/upload',
    DELETE: '/file/delete',
    DOWNLOAD: '/file/download'
  },

  // 文章管理API
  ARTICLE: {
    LIST: '/article/list',
    CREATE: '/article/create',
    UPDATE: '/article/update',
    DELETE: '/article/delete',
    SEARCH: '/article/search'
  }
}

// 生成完整API URL的辅助函数
export const getApiUrl = (endpoint) => {
  return `${API_CONFIG.BASE_URL}${endpoint}`
}

// 导出配置
export default API_CONFIG 